package router

import (
	"github.com/gin-gonic/gin"
	"user_bff/controller"
	"user_bff/middleware"
)

func InitRouter() *gin.Engine {
	router := gin.Default()
	router.POST("/user/login", controller.UserLogin)       //用户登录
	router.POST("/refresh/token", controller.RefreshToken) //刷新令牌
	router.Use(middleware.UserLoginAuth())
	return router
}
